package com.hamster.crmpre.service.impl;

import com.hamster.crmpre.mapper.DictionaryDepartmentMapper;
import com.hamster.crmpre.service.DepartmentIdQueryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author ：Lizhipeng
 * @date ：Created in 2019/12/27 8:41
 * @description：DepartmentIDQueryService实现类
 * @modified By：
 * @version:
 */
@Service
public class DepartmentIdQueryServiceImpl implements DepartmentIdQueryService {

    @Autowired
    private DictionaryDepartmentMapper dictionaryDepartmentMapper;

    /**
     * 获取部门id编号
     * @param department 部门名字
     * @return
     */
    @Override
    public String get(String department) {
        return dictionaryDepartmentMapper.queryIdByTitle(department);
    }


}
